﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<%set (string){category_title}=get_category_title({category_id},"商品展示")%>
<title>{category_title} - {config.webname}</title>
<link rel="stylesheet" href="{config.templateskin}/css/style.css" />
<link rel="stylesheet" href="{config.webpath}css/pagination.css" />
<script type="text/javascript" src="{config.webpath}scripts/jquery/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="{config.templateskin}/js/base.js"></script>
</head>
<body>
<div class="container_12">
 <!-- .header -->
 <%template src=/_header.html/%>
 <!-- /.header -->
 <div class="clear"></div>
 <div class="grid_8">
  <%set (string){category_nav}=get_category_menu("goods_list1", category_id)%>
  <h2 class="page_title"><a href="<%linkurl("goods_list","")%>">商品展示</a>{category_nav}</h2>
  <div class="page_product_list">
   <ul>
    <%set (DataTable){list}=get_photo_list(channel_id, category_id, 9, page, "", out totalcount)%> <!--取得一个DataTable-->
    <%set (string){pagelist}=get_page_link(9, page, totalcount, "goods_list1", category_id, "__id__")%> <!--取得分页页码列表-->
    <%loop dr list%>
    <li><a href="<%linkurl("goods_show",{dr[id]})%>"><img src="{dr[img_url]}" alt="{dr[title]}" />
    <span>{dr[title]}</span></a>
    <b>价格：￥{dr[sell_price]}元</b>
    </li>
    <%/loop%>
  </ul>
  </div>
  <div class="line10"></div>
  <div class="flickr">{pagelist}</div> <!--放置页码列表-->
  <div class="line10"></div>
 </div>
 <!-- end content -->
 <div class="grid_4 sidebar">
  <!--类别-->
   <ul class="sidebar_nav">
    <%set (DataTable){category_list}=get_category_list(channel_id, 0)%>
    <%loop cdr category_list%>
    <li>
      <%csharp%>
      int layer_width=(Convert.ToInt32(cdr["class_layer"])-1)*18;
      <%/csharp%>
      <span style="width:{layer_width}px;text-align:right;display:inline-block;"></span>
      <a href="<%linkurl("goods_list1",{cdr[id]},1)%>">{cdr[title]}</a></li>
    <%/loop%>
  </ul>
  <!--/类别-->
  <h2><a href="<%linkurl("goods_list","")%>">商品排行榜</a></h2>
  <div class="hot_list">
     <ul>
       <%set (DataTable){photo_list10}=get_photo_list(channel_id, category_id, 10, "is_lock=0", "digg_good desc,add_time desc")%>
       <%loop pdr10 photo_list10%>
       <%if pdr10__loop__id==1%>
       <li class="first">
         <b><a href="<%linkurl("goods_show",{pdr10[id]})%>">{pdr10[title]}</a></b>
         <p><%cutstring({pdr10[content]},80)%></p>
       </li>
       <%continue%>
       <%/if%>
       <li><span>( <%datetostr({pdr10[add_time]},MM-dd)%> )</span><a href="<%linkurl("goods_show",{pdr10[id]})%>"><%cutstring({pdr10[title]},28)%></a></li>
       <%/loop%>
     </ul>
   </div>
  
 </div>
 <!-- end sidebar -->
 <!-- .footer -->
 <%template src=/_footer.html/%>
 <!-- /.footer -->
</div>
</body>
</html>